#!/bin/sh

query="$1"
flag="-n"
if test "$1" = "-n"; then
  flag=""
  query="$2"
fi

full=`git grep $flag "$1" | pick`
file=`echo "$full" | cut -d : -f 1-2`
echo "$file"
